import QtQuick 2.0

Item {
    property bool active: false;
    property alias color: rectBack.color;
    signal clicked;

    id: root;
    width: 48;
    height: 48;

    Rectangle {
        id: rectBack;
        anchors.fill: parent;

        border.width: 2;
        border.color: active ? "#666666" : "#f0f0f0";
    }

    MouseArea {
        anchors.fill: parent;

        onClicked: {
            root.clicked();
        }
    }
}
